<div id="actionbar">
    <sapn url="{:url('storeCate/add',['parent_id'=>$parent_id])}" class="button button-blue win"> <i class="iconfont icon-add_icon"></i>创建主类</span>
</div>
<table class="pure-table">
    <thead>
    <tr>
        <th class="w60 fn-tac">排序</th>
        <th class="w60 fn-tac"></th>
        <th>分类名称</th>
        <th>分类别名</th>
        <th class="w140">更新时间</th>
        <th class="w240 fn-tac">操作</th>
    </tr>
    </thead>
    <tbody>
    {foreach $lists as $vo}
    <tr>
        <td class="fn-tac"><input name="sort" class="fn-tac w40 input input-mini sort" type="text" value="{$vo['sort']}" id="{$vo.id}" /></td>
        <td class="fn-tac"><img class="w40" src="{$vo['picture']}" /></td>
        <td><a href="{:url('storeCate/index',['parent_id'=>$vo.id])}">{$vo.title}</a></td>
        <td>{$vo.name}</td>
        <td>{$vo.update_time|date='Y-m-d H:i'}</td>
        <td class="button-group">
            <sapn id="btnMenu" class="button"><i class="iconfont icon-list_icon"></i>菜单</sapn>
            <!-- <sapn class="button win" url="{:url('storeCate/add',['parent_id'=>$vo.id])}"><i class="iconfont icon-add_icon"></i>创建</sapn> -->
            <sapn class="button win" url="{:url('storeCate/edit',array('id'=>$vo.id))}"><i class="iconfont icon-edit"></i>编辑</sapn>
            <sapn class="button isDel" url="{:url('storeCate/delete',array('id'=>$vo.id))}"><i class="iconfont icon-lajixiang"></i>删除</sapn>
        </td>
    </tr>  
    {/foreach}
    </tbody>
</table>
<script type="text/javascript">
Do('base', 'layer','menu',function () {
    $('.isDel').actUrl();
    $(".sort").changeUrl({
        url:"{:url('storeCate/sort')}"
    })
    $('.win').win({area: ['500px', '400px'],'reload':true});

    $('#btnMenu').click(function(){
        var ids = $(this).attr("id");
        var menuData = [
            {content:'News Site',header: true},//定义子标题栏
            {content:'163 NetEase',url :'{:url("storeCate/edit")}?id='+ids,callback:function(){

            }},
            {content:'asdf',callback : function(re){
                 alert(re);
            }}
        ];
        $(this).selectMenu({
            regular : true,
            data : menuData
        });
    });
})
</script>